<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  

  <script>
  let str = 'They are students'; let sub = 'aeiou';
  // function characterDeletion(str, sub) {
  //   let arr = [...new Set(sub.split(''))]
  //   return str.replace(new RegExp(arr.join('|'), 'g'), '')
  // }


    let str = "a(b(c(de)fgh)";

    relpaceS(str);

    function relpaceS(str) {
      
    }

    console.log(relpaceS(str));

  // console.log(characterDeletion(str, sub))
  </script>
</body>
</html>